<!DOCTYPE html>
<html>
<head>
    <title>消息推送模块</title>
    #parse("sys/header.html")
</head>
<body>
<div id="rrapp" v-cloak>
    <div v-show="showList">
        <div id="queryDiv" class="queryDiv">
            <div class="grid-btn">
                <div class="form-group col-sm-2 keyword">
                    <input type="text" class="form-control" id="keyword" @keyup.enter="query"
                           placeholder="主键 / 备注">
                </div>
                <a class="btn btn-primary" @click="query">查询</a>

                <!--#if($shiro.hasPermission("glass/glass:save"))-->
                <!--<a class="btn btn-primary" @click="add"><i class="fa fa-plus"></i>&nbsp;新增</a>-->
                <!--#end-->
                #if($shiro.hasPermission("glass/message:update"))
                <a class="btn btn-primary" @click="update"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</a>
                #end
                #if($shiro.hasPermission("glass/message:delete"))
                <a class="btn btn-primary" @click="del"><i class="fa fa-trash-o"></i>&nbsp;删除</a>
                #end
            </div>
        </div>
        <table id="jqGrid"></table>
        <div id="jqGridPager"></div>
    </div>

    <div v-show="!showList" class="panel panel-default">
        <div class="panel-heading">{{title}}</div>
        <form class="form-horizontal">
            <div class="form-group">
                <div class="col-sm-2 control-label">id</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.id" placeholder="id"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">时区</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.deliverytimezone" placeholder="时区"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">消息内容</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.alert" placeholder="消息内容"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">推送类别</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.recipienttype"
                           placeholder="推送类别 broadcast:全体 tags:标签推送 alias:单人"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">设备标签</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.devicetags" placeholder="设备标签"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">设备别名</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.devicealias" placeholder="设备别名"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">deviceregistrationid</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.deviceregistrationid"
                           placeholder="deviceregistrationid"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">devicesegmentid</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.devicesegmentid"
                           placeholder="devicesegmentid"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">平台</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.android" placeholder="平台"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">aps</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.aps" placeholder="aps"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">推送时间 now</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.deliverytype" placeholder="推送时间 now"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">deliverydate</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.deliverydate" placeholder="deliverydate"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">deliverytime</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.deliverytime" placeholder="deliverytime"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">durationtime</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.durationtime" placeholder="durationtime"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">离线时长</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.timetolive" placeholder="离线时长"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label">推送附带参数</div>
                <div class="col-sm-10">
                    <input type="text" class="form-control" v-model="message.customkeys" placeholder="推送附带参数"/>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-2 control-label"></div>
                <input type="button" class="btn btn-primary" @click="saveOrUpdate" value="确定"/>
                &nbsp;&nbsp;<input type="button" class="btn btn-warning" @click="reload" value="返回"/>
            </div>
        </form>
    </div>
</div>

<script src="${rc.contextPath}/js/glass/message/message.js?_${date.systemTime}"></script>
</body>
</html>